<script src="js/workflow/CCBX/printCCBXview.js"></script>
<script type="text/javascript" src="assets/print/jquery-migrate-1.2.1.min.js"></script>
<script type="text/javascript" src="assets/print/html2canvas.min.js"></script>
<script type="text/javascript" src="assets/print/jquery.jqprint-0.3.js"></script>

<section id="main-content">
    <section class="wrapper" ng-repeat="printItem in printDataList">

        <div class="row" ng-show="{{apploged}}">
            <div class="col-lg-12">
                <div class="alert alert-block alert-danger fade in">
                    <button data-dismiss="alert" class="close close-sm" type="button">
                        <i class="icon-remove"></i>
                    </button>
                    <strong>友情提示：</strong>
                    报销流程审批已结束！
                </div>
            </div>
        </div>
        <div class="row">
            <div class="col-lg-12">
                <!-- 结果页 -->
                <div class="alert alert-block alert-danger fade in">
                    <button data-dismiss="alert" class="close close-sm" type="button">
                        <i class="icon-remove"></i>
                    </button>
                    <strong>友情提示：</strong>
                    请务必将打印的纸质单据递交至财务部，便于财务核实汇款工作，谢谢配合！
                </div>
                <section class="panel">
                    <div class="panel-body">

                        <div class="printbox">
                            <div class="wrap-content containerPrint" id="containerPrint-1"
                                style="width: 1000px;">
                                <table style="font-size: 12px;color: #000;border-collapse:collapse;" cellspacing="0"
                                    cellpadding="0">
                                    <thead>
                                        <tr style="text-align: center;color: #000;">
                                            <td style="font-size: 16px;" colspan="15">差旅费报销单</td>
                                        </tr>
                                        <tr style="text-align: right;">
                                            <td colspan="14">
                                                <span style="float: left;padding-right: 20px;">申请部门：{{compName}}—{{printItem.totalEntity.departmentName}}</span>
                                                <span style="float: left;padding-right: 20px;">申请人：{{printItem.totalEntity.applyManName}}</span>
                                                <span style="float: left;">日期：{{printItem.totalEntity.createTime |
                                                    date:'yyyy-MM-dd'}}</span>
                                                <span style="float: right;">单据编号：{{printItem.totalEntity.financialCodeEntity}}</span>
                                            </td>
                                        </tr>
                                    </thead>
                                    <tbody style="border:1px solid #000;">
                                        <tr style="border:1px solid #000;text-align: center;">
                                            <td style="border:1px solid #000;"></td>
                                            <td style="border:1px solid #000;" colspan="2">出差日期</td>
                                            <td style="border:1px solid #000;" colspan="3">出差内容</td>
                                            <td style="border:1px solid #000;" colspan="2">车票</td>
                                            <td style="border:1px solid #000;" colspan="2">其他费用</td>
                                            <td style="border:1px solid #000;"></td>
                                            <td style="border:1px solid #000;" colspan="2">补助</td>
                                            <td style="border:1px solid #000;"></td>
                                        </tr>
                                        <tr style="border:1px solid #000;text-align: center;">
                                            <td style="border:1px solid #000;width:30px;">序号</td>
                                            <td style="border:1px solid #000;width:105px;">起始时间</td>
                                            <td style="border:1px solid #000;width:105px;">终止时间</td>
                                            <td style="border:1px solid #000;width:135px;">项目名称</td>
                                            <td style="border:1px solid #000;width:70px;">开始地点</td>
                                            <td style="border:1px solid #000;width:75px;">结束地点</td>
                                            <!-- <td style="border:1px solid #000;width:65px;">类型</td> -->

                                            <td style="border:1px solid #000;width:65px;">火车/汽车</td>
                                            <td style="border:1px solid #000;width:65px;">飞机</td>

                                            <td style="border:1px solid #000;width:65px;">交通费</td>
                                            <!-- <td style="border:1px solid #000;width:65px;">招待费</td> -->
                                            <td style="border:1px solid #000;width:65px;">其他</td>

                                            <td style="border:1px solid #000;width:65px;">住宿费</td>

                                            <td style="border:1px solid #000;width:65px;">出差天数</td>
                                            <td style="border:1px solid #000;width:65px;">出差补助</td>

                                            <td style="border:1px solid #000;width:65px;">小计</td>

                                        </tr>
                                        <tr style="border:1px solid #000;text-align: center;" ng-repeat="cc in printItem.pageItemList">
                                            <td style="border:1px solid #000;">{{$index+1}}</td>
                                            <td style="border:1px solid #000;">{{cc.startTime | date:'yyyy-MM-dd
                                                hh:mm'}}</td>
                                            <td style="border:1px solid #000;">{{cc.endTime | date:'yyyy-MM-dd hh:mm'}}</td>
                                            <td style="border:1px solid #000;">{{cc.projName}}</td>
                                            <td style="border:1px solid #000;">{{cc.startAddr}}</td>
                                            <td style="border:1px solid #000;">{{cc.endAddr}}</td>
                                            <!-- <td style="border:1px solid #000;">{{getExpenseType(cc.expenseType)}}</td> -->

                                            <td style="border:1px solid #000;">{{cc.train}}</td>
                                            <td style="border:1px solid #000;">{{cc.plan}}</td>

                                            <td style="border:1px solid #000;">{{cc.traffic}}</td>
                                            <!-- <td style="border:1px solid #000;">{{cc.repetition}}</td> -->
                                            <td style="border:1px solid #000;">{{cc.others}}</td>

                                            <td style="border:1px solid #000;">{{cc.hotel}}</td>

                                            <td style="border:1px solid #000;">{{cc.travelAllowanceDays}}</td>
                                            <td style="border:1px solid #000;">{{cc.travelAllowance}}</td>


                                            <td style="border:1px solid #000;">{{cc.subTotal}}</td>

                                        </tr>
                                    </tbody>
                                    <tfoot>
                                        <tr>
                                            <td style="text-align: left;" colspan="6">金额大写：{{rmb}} </td>
                                            <td style="text-align: right;" colspan="9">合计总金额：{{ccbxItemRepeatss.totalAmount}}</td>
                                        </tr>
                                    </tfoot>
                                </table>
                                <p style="color: #000;font-size: 12px;">
                                    备注:
                                    <br /> 1.金额不得涂改(金额大写壹、贰、叁、肆、伍、陆、柒、捌、玖、拾、佰、仟、万、亿、元、角、分、零、整);
                                    <br /> 2.特殊城市:北京、深圳、珠海、厦门、广州、汕头、上海、杭州、海南,其他为一般城市;
                                    <br /> 3.出差补助说明:80元/天;
                                    <br /> 3.入职和南京总部培训(享受30元/天餐费补贴,无须提供发票).
                                    <span style="float: right;">领款人签字：__________________________________________________</span>
                                </p>
                                <table style="width: 100%;font-size:12px;color: #000;text-align: center;border-collapse:collapse;"
                                    cellspacing="0" cellpadding="0" ng-show="{{applog}}">
                                    <thead style="text-align: center">
                                        <tr style="text-align: center">
                                            <th style="width:50px;text-align: center;">序号</th>
                                            <th style="width:150px;text-align: center;">节点名称</th>
                                            <th style="width:250px;text-align: center;">电子签名</th>
                                            <th style="width:150px;text-align: center;">签名日期</th>
                                            <th style="width:100px;text-align: center;">操作</th>
                                            <th style="width:300px;text-align: left;">留言</th>
                                        </tr>
                                    </thead>
                                    <tbody style="text-align: center">
                                        <tr ng-repeat='trace in printItem.singProcess'>
                                            <td>{{$index+1}}</td>
                                            <td>
                                                <span style="display:inline-block; text-decoration: underline">{{trace.taskName}}</span>
                                            </td>
                                            <td>
                                                <span style="display:inline-block; text-decoration: underline">{{trace.USER}}</span>
                                                <!--<span style="display:inline-block; text-decoration: underline">运营管理部</span>-->
                                            </td>
                                            <td>
                                                <span style="display:inline-block; text-decoration: underline">{{trace.time
                                                    | date:'yyyy-MM-dd hh:mm'}}</span>
                                            </td>
                                            <td>
                                                <span style="display:inline-block; text-decoration: underline">{{trace.lastStatus
                                                    | traceStatus}}</span>
                                            </td>
                                            <td>
                                                <span style="display:inline-block; text-decoration: underline;text-align: left;width: 100%;">{{trace.msg}}</span>
                                            </td>
                                        </tr>
                                    </tbody>
                                </table>
                            </div>
                        </div>
                    </div>
                </section>
                <!-- 操作按钮 -->
                <section class="panel">
                    <div class="panel-body">
                        <p class="default-buttons">
                            <a href="javascript:void(0);" class="button-back btn btn-info" onclick="window.history.back()">
                                返回</a>
                            <a href="javascript:void(0);" class="button-next btn btn-info btn-l10" ng-click="closePrintViewCCBX()">转入财务汇款</a>
                            <!--<a href="javascript:void(0);" class="button-next  btn btn-success" ng-click="printpageBX(printItem.totalEntity.financialCodeEntity)">-->
                            <a href="javascript:void(0);" class="button-next  btn btn-success" ng-click="printpageBX()">
                                <i class="icon-print"></i> 打印单据</a>
                        </p>
                    </div>
                </section>

                
                <!-- 图片生成 -->
                <section class="panel printImg" style="display: none;">
                    <header class="panel-heading">本地图片</header>
                   <!-- <div class="panel-body" id="printImgBox-{{printItem.totalEntity.financialCodeEntity}}"></div>-->
                    <div class="panel-body" id="printImgBox-1"></div>
                </section>
            </div>
        </div>
    </section>
</section>